<?php
/**
 *
 * 协议地址配置
 *
 * SchemeConst.class.php
 * Created by IntelliJ IDEA.
 *
 * @author: hjh <hjh@jf.com>
 *
 * Date: 2017/9/8
 * Time: 10:22
 */

namespace Constants;

class SchemeConstant
{
    const APP_MAIN = 'gold://app/main';          //启动
    const APP_WALLET = 'gold://app/wallet';      //钱包
    const APP_H5 = 'gold://app/url?url=%s';     //H5地址
    const APP_ACTIVE = 'gold://app/active?id=%s';
    const APP_TICKET = 'gold://app/ticket?id=%s';
    const APP_VIP = 'gold://app/vip?id=%s';
    const APP_PRIZE = 'gold://app/prize?id=%s';
    const APP_ACTIVE_RESULT = 'gold://app/activeResult?id=%s';
    const APP_PRIZE_RESULT = 'gold://app/prizeResult?id=%s';
    const APP_TICKET_RESULT = 'gold://app/ticketResult?id=%s';

    /**
     *  获取H5协议地址
     *
     * @param $url
     * @return string
     */
    public static function getH5Scheme($url)
    {
        return sprintf(self::APP_H5, $url);
    }
}
